#ifndef INIPARSER_H
#define INIPARSER_H

#include <string>
#include <fstream>
#include <map>
#include <iostream>
#include <algorithm>
#include <functional>

class IniParser{
public:
    IniParser() {}
    IniParser(const std::string& file);

    std::string get(const std::string &section,const std::string &key);
protected:
    std::string &ltrim(std::string &s);
    std::string &rtrim(std::string &s);
    std::string &trim(std::string &s);
private:
    typedef std::map<std::string,std::map<std::string,std::string> > MMAP;
    typedef std::map<std::string,std::map<std::string,std::string> >::iterator MMAPIter;

    std::string _file;
    MMAP	_content;
};

#endif
